unit CommTrackBar;

{$ALIGN ON}
{$MINENUMSIZE 4}
{$WEAKPACKAGEUNIT}

interface

uses Windows, Messages;

const
  CCM_FIRST               = $2000;      { Common control shared messages }
  {$EXTERNALSYM CCM_SETUNICODEFORMAT}
  CCM_SETUNICODEFORMAT    = CCM_FIRST + 5;
  {$EXTERNALSYM CCM_GETUNICODEFORMAT}
  CCM_GETUNICODEFORMAT    = CCM_FIRST + 6;
  {$EXTERNALSYM TRACKBAR_CLASS}
  TRACKBAR_CLASS = 'msctls_trackbar32';

const
  {$EXTERNALSYM TBS_AUTOTICKS}
  TBS_AUTOTICKS           = $0001;
  {$EXTERNALSYM TBS_VERT}
  TBS_VERT                = $0002;
  {$EXTERNALSYM TBS_HORZ}
  TBS_HORZ                = $0000;
  {$EXTERNALSYM TBS_TOP}
  TBS_TOP                 = $0004;
  {$EXTERNALSYM TBS_BOTTOM}
  TBS_BOTTOM              = $0000;
  {$EXTERNALSYM TBS_LEFT}
  TBS_LEFT                = $0004;
  {$EXTERNALSYM TBS_RIGHT}
  TBS_RIGHT               = $0000;
  {$EXTERNALSYM TBS_BOTH}
  TBS_BOTH                = $0008;
  {$EXTERNALSYM TBS_NOTICKS}
  TBS_NOTICKS             = $0010;
  {$EXTERNALSYM TBS_ENABLESELRANGE}
  TBS_ENABLESELRANGE      = $0020;
  {$EXTERNALSYM TBS_FIXEDLENGTH}
  TBS_FIXEDLENGTH         = $0040;
  {$EXTERNALSYM TBS_NOTHUMB}
  TBS_NOTHUMB             = $0080;
  {$EXTERNALSYM TBS_TOOLTIPS}
  TBS_TOOLTIPS            = $0100;

  {$EXTERNALSYM TBM_GETPOS}
  TBM_GETPOS              = WM_USER;
  {$EXTERNALSYM TBM_GETRANGEMIN}
  TBM_GETRANGEMIN         = WM_USER+1;
  {$EXTERNALSYM TBM_GETRANGEMAX}
  TBM_GETRANGEMAX         = WM_USER+2;
  {$EXTERNALSYM TBM_GETTIC}
  TBM_GETTIC              = WM_USER+3;
  {$EXTERNALSYM TBM_SETTIC}
  TBM_SETTIC              = WM_USER+4;
  {$EXTERNALSYM TBM_SETPOS}
  TBM_SETPOS              = WM_USER+5;
  {$EXTERNALSYM TBM_SETRANGE}
  TBM_SETRANGE            = WM_USER+6;
  {$EXTERNALSYM TBM_SETRANGEMIN}
  TBM_SETRANGEMIN         = WM_USER+7;
  {$EXTERNALSYM TBM_SETRANGEMAX}
  TBM_SETRANGEMAX         = WM_USER+8;
  {$EXTERNALSYM TBM_CLEARTICS}
  TBM_CLEARTICS           = WM_USER+9;
  {$EXTERNALSYM TBM_SETSEL}
  TBM_SETSEL              = WM_USER+10;
  {$EXTERNALSYM TBM_SETSELSTART}
  TBM_SETSELSTART         = WM_USER+11;
  {$EXTERNALSYM TBM_SETSELEND}
  TBM_SETSELEND           = WM_USER+12;
  {$EXTERNALSYM TBM_GETPTICS}
  TBM_GETPTICS            = WM_USER+14;
  {$EXTERNALSYM TBM_GETTICPOS}
  TBM_GETTICPOS           = WM_USER+15;
  {$EXTERNALSYM TBM_GETNUMTICS}
  TBM_GETNUMTICS          = WM_USER+16;
  {$EXTERNALSYM TBM_GETSELSTART}
  TBM_GETSELSTART         = WM_USER+17;
  {$EXTERNALSYM TBM_GETSELEND}
  TBM_GETSELEND           = WM_USER+18;
  {$EXTERNALSYM TBM_CLEARSEL}
  TBM_CLEARSEL            = WM_USER+19;
  {$EXTERNALSYM TBM_SETTICFREQ}
  TBM_SETTICFREQ          = WM_USER+20;
  {$EXTERNALSYM TBM_SETPAGESIZE}
  TBM_SETPAGESIZE         = WM_USER+21;
  {$EXTERNALSYM TBM_GETPAGESIZE}
  TBM_GETPAGESIZE         = WM_USER+22;
  {$EXTERNALSYM TBM_SETLINESIZE}
  TBM_SETLINESIZE         = WM_USER+23;
  {$EXTERNALSYM TBM_GETLINESIZE}
  TBM_GETLINESIZE         = WM_USER+24;
  {$EXTERNALSYM TBM_GETTHUMBRECT}
  TBM_GETTHUMBRECT        = WM_USER+25;
  {$EXTERNALSYM TBM_GETCHANNELRECT}
  TBM_GETCHANNELRECT      = WM_USER+26;
  {$EXTERNALSYM TBM_SETTHUMBLENGTH}
  TBM_SETTHUMBLENGTH      = WM_USER+27;
  {$EXTERNALSYM TBM_GETTHUMBLENGTH}
  TBM_GETTHUMBLENGTH      = WM_USER+28;
  {$EXTERNALSYM TBM_SETTOOLTIPS}
  TBM_SETTOOLTIPS         = WM_USER+29;
  {$EXTERNALSYM TBM_GETTOOLTIPS}
  TBM_GETTOOLTIPS         = WM_USER+30;
  {$EXTERNALSYM TBM_SETTIPSIDE}
  TBM_SETTIPSIDE          = WM_USER+31;

  // TrackBar Tip Side flags
  {$EXTERNALSYM TBTS_TOP}
  TBTS_TOP                = 0;
  {$EXTERNALSYM TBTS_LEFT}
  TBTS_LEFT               = 1;
  {$EXTERNALSYM TBTS_BOTTOM}
  TBTS_BOTTOM             = 2;
  {$EXTERNALSYM TBTS_RIGHT}
  TBTS_RIGHT              = 3;

  {$EXTERNALSYM TBM_SETBUDDY}
  TBM_SETBUDDY            = WM_USER+32; // wparam = BOOL fLeft; (or right)
  {$EXTERNALSYM TBM_GETBUDDY}
  TBM_GETBUDDY            = WM_USER+33; // wparam = BOOL fLeft; (or right)
  {$EXTERNALSYM TBM_SETUNICODEFORMAT}
  TBM_SETUNICODEFORMAT    = CCM_SETUNICODEFORMAT;
  {$EXTERNALSYM TBM_GETUNICODEFORMAT}
  TBM_GETUNICODEFORMAT    = CCM_GETUNICODEFORMAT;

  {$EXTERNALSYM TB_LINEUP}
  TB_LINEUP               = 0;
  {$EXTERNALSYM TB_LINEDOWN}
  TB_LINEDOWN             = 1;
  {$EXTERNALSYM TB_PAGEUP}
  TB_PAGEUP               = 2;
  {$EXTERNALSYM TB_PAGEDOWN}
  TB_PAGEDOWN             = 3;
  {$EXTERNALSYM TB_THUMBPOSITION}
  TB_THUMBPOSITION        = 4;
  {$EXTERNALSYM TB_THUMBTRACK}
  TB_THUMBTRACK           = 5;
  {$EXTERNALSYM TB_TOP}
  TB_TOP                  = 6;
  {$EXTERNALSYM TB_BOTTOM}
  TB_BOTTOM               = 7;
  {$EXTERNALSYM TB_ENDTRACK}
  TB_ENDTRACK             = 8;

  // custom draw item specs
  {$EXTERNALSYM TBCD_TICS}
  TBCD_TICS    = $0001;
  {$EXTERNALSYM TBCD_THUMB}
  TBCD_THUMB   = $0002;
  {$EXTERNALSYM TBCD_CHANNEL}
  TBCD_CHANNEL = $0003;


implementation

end.